//进行API统一管理
import requests from './request';


const getHeaders = {
    'Content-Type': 'application/x-www-form-urlencoded',
}

//大气环境-报警列表，报警记录统计
export function getAqmsOfAlarm(params) {
    return requests({
        url: 'ipes-prj-third-server/api/v1/web/alarm/getAqmsOfAlarm',
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}

//大气环境监测-当天24小时废气超标统计
export function getWgOverLast24Hours(params) {
    return requests({
        url: 'ipes-prj-third-server/api/v1/web/alarm/getWgOverLast24Hours',
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}

// 污染源监测-报警列表，报警记录统计
export function getPomsOfAlarm(params) {
    return requests({
        url: 'ipes-prj-third-server/api/v1/web/alarm/getPomsOfAlarm',
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}
// 综合态势-上报事件，本月巡查事件统计
export function getReportingEventsNumber(params) {
    return requests({
        url: 'ipes-prj-third-server/api/v1/web/alarm/getReportingEventsNumber',
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}
// 综合态势-今日，本月，本年巡查次数统计
export function getInspectNumber(params) {
    return requests({
        url: 'ipes-prj-third-server/api/v1/web/alarm/getInspectNumber',
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}
// 综合态势-当天24小时废水超标次数统计
export function getWwOverLast24Hours(params) {
    return requests({
        url: 'ipes-prj-third-server/api/v1/web/alarm/getWwOverLast24Hours',
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}
// 综合态势监测 当月报警记录，报警列表
export function getComprehensiveOfAlarm(params) {
    return requests({
        url: 'ipes-prj-third-server/api/v1/web/alarm/getComprehensiveOfAlarm',
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}
// 重点监管企业，当天预警点位,正常点位个数统计
export function getCourentDayAlarmSite(params) {
    return requests({
        url: 'ipes-prj-third-server/api/v1/web/alarm/getCourentDayAlarmSite',
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}
// 预警详情接口
export function getDetailsOfAlarmById(params) {
    return requests({
        url: 'ipes-prj-third-server/api/v1/web/alarm/getDetailsOfAlarm/' + params.alarmId,
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}
// 空气质量 - 24小时趋势
export function get24HoursTrend(params) {
    return requests({
        url: 'ipes-prj-third-server/api/v1/web/airenv/get24HoursTrend?timeField=hours&factorCode=AQI',
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}
//  空气质量 - 主要污染物分析
export function getMainPollutant(params) {
    return requests({
        url: 'ipes-prj-third-server/api/v1/web/airenv/getMainPollutant',
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}
//  空气质量 - 地图点位
export function getSiteData(params) {
    return requests({
        url: 'ipes-prj-third-server/api/v1/web/airenv/getSiteData',
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}
//  空气质量 - 大气环境
export function getAirEnv(params) {
    return requests({
        url: 'ipes-prj-third-server/api/v1/web/airenv/getAirEnv',
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}
//  空气质量 - 实时空气质量
export function getRealAqiReport(params) {
    return requests({
        url: 'ipes-prj-third-server/api/v1/web/airenv/getRealAqiReport',
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}
//  空气质量 - 点位实时数据
export function getSiteRealData(params) {
    return requests({
        url: 'ipes-prj-third-server/api/v1/web/airenv/getSiteRealData?siteCode=RDKFQKQZDJCZ01&monitorType=aqms',
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}
//  空气质量 - 空气质量年趋势分析
export function getYearAqiTrend(params) {
    return requests({
        url: 'ipes-prj-third-server/api/v1/web/airenv/getYearAqiTrend',
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}
//  空气质量 - 空气质量日历
export function getAqiDailyData(params) {
    return requests({
        url: 'ipes-prj-third-server/api/v1/web/airenv/getAqiDailyData',
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}
//  污染源监测 - 今年超标排污单位数量
export function getChaoBiaoCompanyNum(params) {
    return requests({
        url: 'ipes-prj-third-server/public/api/v1/web/pollutionSourceData/getChaoBiaoCompanyNum',
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}
//  污染源监测 - 今年重点监测企业排污超标次数
export function getCurrentYearCompanyData(params) {
    return requests({
        url: 'ipes-prj-third-server/public/api/v1/web/pollutionSourceData/getCurrentYearCompanyData',
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}

//  污染源监测 - 噪音接口数据
export function getNoiseData(params) {
    return requests({
        url: 'ipes-prj-third-server/public/api/v1/web/pollutionSourceData/getNoiseData',
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}
//  污染源监测 - 排污单位列表
export function getCompanyList(params) {
    return requests({
        url: 'ipes-prj-third-server/public/api/v1/web/pollutionSourceData/getCompanyList',
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}
//  污染源监测 - 每日污染防治监测
export function pollutionPreventionMonitoring(params) {
    return requests({
        url: 'ipes-prj-third-serverpublic/api/v1/web/pollutionSourceData/pollutionPreventionMonitoring',
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}
//  污染源监测 - 重点监测企业污染源监测
export function getKeyMonitor(params) {
    return requests({
        url: 'ipes-prj-third-server/public/api/v1/web/pollutionSourceData/getKeyMonitor',
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}
//  污染源监测 - 重点监测数据
export function keyMonitoringData(params) {
    return requests({
        url: 'ipes-prj-third-server/public/api/v1/web/pollutionSourceData/keyMonitoringData',
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}
//  污染源监测 - 环境执法监督
export function getComplaintData(params) {
    return requests({
        url: 'ipes-prj-third-server/public/api/v1/web/pollutionSourceData/getComplaintData',
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}

//空气，扬尘点位详情展示
export function getSiteReal(params) {
    return requests({
        url: 'ipes-prj-third-server/api/v1/web/airenv/getSiteRealData',
        method: 'get',
        params: params,
        headers: getHeaders,
    })
}